Back to Main Menu

Attribute Fields - Asset and Functional Location

Introduction

For both Assets and Functional Location there is a set of 'core' attribute fields that are common to all assets/Functional Locations.

 

The Asset and Functional Location API's explicitly define these fields, which are listed in the article Asset Integration Overview.

 

All other attribute fields are passed to the API as a list, and may differ from asset category to asset category, though there is a large number of attribute fields that are still common to most asset categories.

 

Likewise for Functional Location Type, the list of attribute fields will differ.

 

This article describes how to get the correct field names to use in the Asset/Functional Location API's for defining the list of attribute fields to operate on.  These API's requires Assetic 'internal' field names, so the field names presented in the Assetic UI (labels) cannot be used.

Get Assetic Field Name for Field Label

The OData metadata endpoint can be used to get the list of field names (internal name) with the associated field label (field name in Assetic UI and Data Exchange).  Open this link in your browser to view the metadata (replace [your_env] with your site name).
https://[your_env].assetic.net/odata/$metadata

Entity Type

In the XML response from the metadata is a set of Entity Types:

 

If looking for asset attributes expand the 'assets' Entity Type, and for Functional Location expand the 'functionallocations' Entity Type.

 

Search for Attribute

Use the browser 'Find' to search for the attribute name as it appears in the Assetic UI (which also corresponds to the attribute name used in Data Exchange upload files).  When you find the attribute name, you will see the internal field name you need to use in the XML configuration.
The screenshot below shows for the field label "Apron Type" the internal field name is "ApronType".  Also note the field type is 'string'.

 

With the OData metadata be aware that the response includes several API endpoints, so make sure your "Apron Type" definition is coming from the 'assets' Entity Type.

Determine if Field is valid for category

Non-asset Fields

The "assets" OData Entity Type has joins to other records such as 'Functional Location'.  This means some Functional Location fields are listed under the 'assets' Entity Type, but these fields cannot be used with the Asset API's.

 

This means that the existence of a field in OData metadata doesn't mean the field is supported by the API.

Category Specific Fields

The OData metadata includes all fields, but the list of attributes differs between Asset Categories.

As an example, the attribute field "ApronType" is not valid for all asset categories.

Field List from Category Admin module

To verify what fields are in any given asset category, a spreadsheet can be obtained from the Admin section of Assetic, on a per category basis (requires 'admin' role).
There is a button 'Category Fields' that will initiate the download as per the article Asset Category Fields.

In the Excel file, the column with the header 'ControlLabel' has the user-friendly attribute field names available in that Asset Category.  This file also provides the field type and length of the attribute.  

 

Field List from Data Exchange

An alternative approach to obtaining the field list of an Asset Category is via the Data Exchange template for the Asset Category.  This is useful if the 'Admin' module of Assetic is inaccessible due to insufficient access rights.   This is described in the Assetic Knowledge Base article Export Data Fields.